'''
控制层：实现界面打印和菜单选择
'''
import market


def main():
    while True:
        print('-------欢迎来到----------------')
        print('1查看商品2查找商品3添加商品4修改商品5删除商品6查看所有订单7删除订单8订单统计9商品结算')
        choice = int(input('请输入你的选择：'))
        if choice == 1:
            market.show_product()
        elif choice == 2:
            market.login()
        elif choice == 3:
            print('正在退出')
        elif choice == 4:
            market.login()
        elif choice == 5:
            market.login()
        elif choice == 6:
            market.login()
        elif choice == 7:
            market.login()
        elif choice == 8:
            market.login()
            break
        else:
            print('输入有误')


if __name__ == '__main__':
    main()
